<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改单元信息')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-unit-edit" th:object="${fzBuildingUnit}">
            <div class="form-group">
                <label class="col-sm-3 control-label is-required">单元ID：</label>
                <div class="col-sm-8">
                    <input readonly="true"  name="unitId" th:field="*{unitId}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label is-required">单元编号</label>
                <div class="col-sm-8">
                    <input name="unitNum" th:field="*{unitNum}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label is-required">是否有电梯</label>
                <div class="col-sm-8">
                    <label class="radio-box"> <input type="radio" name="lift" value="0" checked/> 有 </label>
                    <label class="radio-box"> <input type="radio" name="lift" value="1" /> 无 </label>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label is-required">备注</label>
                <div class="col-sm-8">
                    <input name="remark" th:field="*{remark}" class="form-control" type="text" required>
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script type="text/javascript">
        var prefix = ctx + "system/unit";
        $("#form-unit-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-unit-edit').serialize());
            }
        }
    </script>
</body>
</html>